package com.menghanjun.mhjresourcesharing.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.StringSerializer;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.util.Date;
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
public class TResourcesVo {

    private static final long serialVersionUID = 1L;

    /**
     * 资源ID
     */
    @JsonSerialize(using = ToStringSerializer.class)
    private Long resourceId;

    /**
     * 资源标题
     */
    private String title;

    /**
     * 资源路径
     */
    private String url;

    /**
     * 资源描述
     */
    private String description;

    /**
     * 资源类型
     */
    private String type;

    /**
     * 发布者ID
     */
    @JsonSerialize(using = ToStringSerializer.class)
    private Long uploaderId;

    /**
     * 资源等级，免费，vip，收费
     */
    private String level;

    /**
     * 创建时间
     */
    @JsonFormat(shape =JsonFormat.Shape.STRING,pattern ="yyyy-MM-dd HH:mm:ss",timezone ="GMT+8")
    private Date createdAt;


    /**
     * 资源封面
     */
    private String cover;

    /**
     * 发布者名称
     */
    private  String uploaderName;


    /**
     * 点击次数
     */
    private int clickCount;

}
